DisplayCutoutCompat
Represents the area of the display that is not functional for displaying content.
DisplayCutoutCompat
instances are immutable.
Constructors
Link copied to clipboard
Creates a DisplayCutout instance.
constructor(@NonNull safeInsets: Insets, @Nullable boundLeft: Rect, @Nullable boundTop: Rect, @Nullable boundRight: Rect, @Nullable boundBottom: Rect, @NonNull waterfallInsets: Insets)
Creates a DisplayCutout instance.
constructor(@NonNull safeInsets: Insets, @Nullable boundLeft: Rect, @Nullable boundTop: Rect, @Nullable boundRight: Rect, @Nullable boundBottom: Rect, @NonNull waterfallInsets: Insets, @Nullable cutoutPath: Path)
Creates a DisplayCutout instance.
Functions
Link copied to clipboard
Returns a list of
Rect
s, each of which is the bounding rectangle for a non-functional area on the display.Link copied to clipboard
Returns a Path that contains the cutout paths of all sides on the display.
Link copied to clipboard
Returns the inset from the bottom which avoids the display cutout in pixels.
Link copied to clipboard
Returns the inset from the left which avoids the display cutout in pixels.
Link copied to clipboard
Returns the inset from the right which avoids the display cutout in pixels.
Link copied to clipboard
Returns the inset from the top which avoids the display cutout in pixels.
Link copied to clipboard
Returns the insets representing the curved areas of a waterfall display.